import Vue from 'vue'
import VueRouter from 'vue-router'
import HomeView from '../views/HomeView.vue'
import Login from '../views/login.vue'
import User from '../views/user/User.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'login',
    component: Login
  },
  {path: '/login',name: 'login',component: Login},
  {path:'/home',name:'home',component:HomeView,
  children:[
    {path:'/user',component:User},
  ]
},
]

const router = new VueRouter({
  routes
})

export default router
